package com.lingyue.entity.module.biz.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lingyue.entity.groups.Create;
import com.lingyue.entity.groups.Modify;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 *
 * </p>
 *
 * @author deep
 * @version 1.0 on 2020-01-09
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("cov_tag")
@ApiModel(value = "CovTagEntity对象", description = "")
public class CovTagEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "COV_ID", type = IdType.ASSIGN_ID)
    private Long id;

    @ApiModelProperty(value = "标签类型：客户标签/车辆标签")
    @TableField("COV_TYPE")
    @NotNull(groups = {Create.class}, message = "标签类型不能为空")
    private String type;

    @ApiModelProperty(value = "客户/车辆UNIQUE_ID")
    @TableField("COV_REF_UNIQUE_KEY")
    @NotNull(groups = {Create.class}, message = "UNIQUE_ID不能为空")
    private String refUniqueKey;

    @ApiModelProperty(value = "经销商ID")
    @TableField("COV_DEL_ID")
    private Long delId;

    @ApiModelProperty(value = "客户编号")
    @TableField("COV_CUSTOMER_ID")
    @NotNull(groups = {Create.class}, message = "客户编号不能为空")
    private String customerId;

    @ApiModelProperty(value = "标签编号")
    @TableField("COV_TAG_CODE")
    private String tagCode;

    @ApiModelProperty(value = "数据来源\r\n客户标签：NSP/BATCH/ASSISTANT 车辆标签：NSP")
    @TableField("COV_DATA_SOURCE")
    private String dataSource;

    @TableField("COV_CREATE_USER")
    private String createUser;

    @TableField("COV_CREATE_DATE")
    private LocalDateTime createDate;

    @TableField("COV_UPDATE_USER")
    private String updateUser;

    @TableField("COV_UPDATE_DATE")
    private LocalDateTime updateDate;


    public static final String COV_ID = "COV_ID";
    public static final String COV_TYPE = "COV_TYPE";
    public static final String COV_REF_UNIQUE_KEY = "COV_REF_UNIQUE_KEY";
    public static final String COV_DEL_ID = "COV_DEL_ID";
    public static final String COV_CUSTOMER_ID = "COV_CUSTOMER_ID";
    public static final String COV_TAG_CODE = "COV_TAG_CODE";
    public static final String COV_DATA_SOURCE = "COV_DATA_SOURCE";
    public static final String COV_CREATE_USER = "COV_CREATE_USER";
    public static final String COV_CREATE_DATE = "COV_CREATE_DATE";
    public static final String COV_UPDATE_USER = "COV_UPDATE_USER";
    public static final String COV_UPDATE_DATE = "COV_UPDATE_DATE";
}
